package OOday01;

public class Car {
//成员变量，描述对象的属性
       String brand;
        String color;
        double price;
        int capacity;

        //构造方法
    Car(){
    }
    Car(String brand,String color,double price,int capacity){
            this.brand=brand;
            this.color=color;
            this.price=price;
            this.capacity=capacity;}
        //方法，描述对象的行为
        void start(){
            //                  ad.brand             ad.color          ad.price        ad.capacity
            System.out.println(brand+"牌子的"+color+"颜色的"+price+"块钱的"+capacity+"座的车启动了。。。");
        }
        void run(){
            //                 ad.brand            ad.color           ad.price        ad.capacity
            System.out.println(brand+"牌子的"+color+"颜色的"+price+"块钱的"+capacity+"座的车跑起来了。。。");
        }
        void stop(){
            //                 ad.brand             ad.color           ad.price        ad.capaciyt
            System.out.println(brand+"牌子的"+color+"颜色的"+price+"块钱的"+capacity+"座的车停下了。。。");
        }
            }

